const KoaRouter = require('@koa/router');
const { verifyAuth } = require('../middleware/login.middleware');
const { handlAvatar } = require('../middleware/file.middleware');
const { create } = require('../controller/file.controller');


// 1. 创建login路由
const fileRouter = new KoaRouter({ prefix: '/file' });



// 1. 头像上传
fileRouter.post('/avatar', verifyAuth, handlAvatar, create)

module.exports = fileRouter